﻿using jinmaMesProxy.DataAccess;

namespace jinmaMesProxy.Model
{
    [MyTableName("RdRecord09")]

    public class RdRecord09 : MainDetailModel<RdRecords09>
    {
       
        [MyColumnName("bRdFlag")]
        public int RdFlag { get; private set; } = 1;
        [MyColumnName("cVouchType")]
        public string VouchType { get; private set; } = "09";

        [MyColumnName("cBusType")]
        public string BusType { get; private set; } = "其他出库";

        [MyColumnName("cSource")]
        public string Source { get; private set; } = "库存";

        [MyColumnName("cWhCode")]
        public string Warehouse { get; set; }

        [MyColumnName("dDate")]
        public string Date { get; set; } = DateTime.Now.ToString("yyyy-MM-dd 00:00:00.000");
        [MyColumnName("bTransFlag")]
        public int TransFlag { get; private set; } = 0;
        [MyColumnName("cHandler")]
        public string Approver { get; set; } 

        [MyColumnName("cMaker")]
        public string Creator { get; private set; } = RuntimeVariable.OptUser;
        [MyColumnName("dVeriDate")]
        public string ApproveDate { get; set; }
        [MyColumnName("VT_ID")]
        public int TempId { get; set; }
        [MyColumnName("bpufirst")]
        public int PuFirst { get; private set; } = 0;
        [MyColumnName("biafirst")]
        public int IaFirst { get; private set; } = 0;
        [MyColumnName("bFromPreYear")]
        public int FromPreYear { get; private set; } = 0;
        [MyColumnName("bIsLsQuery")]
        public int IsLsQuery { get; private set; } = 0;
        [MyColumnName("bIsComplement")]
        public int IsComplement { get; private set; } = 0;
        [MyColumnName("iDiscountTaxType")]
        public int DiscountTaxType { get; private set; } = 0;
        [MyColumnName("iReturnCount")]
        public int ReturnCount { get; private set; } = 0;
        [MyColumnName("bIsSTQc")]
        public int IsSTQc { get; private set; } = 0;
        [MyColumnName("iverifystate")]
        public int VerifyState { get; private set; } = 0;
        [MyColumnName("iswfcontrolled")]
        public int SwfControlled { get; private set; } = 0;
        [MyColumnName("iPrintCount")]
        public int PrintCount { get; private set; } = 0;
        [MyColumnName("dnmaketime")]
        public string CreateTime { get; set; } = DateTime.Now.ToString("yyyy-MM-dd HH:mm:ss.fff");
        [MyColumnName("dnverifytime")]
        public string ApproveTime { get; set; } 
    }
    [MyTableName("RdRecords09")]
    public class RdRecords09 : DetailModel
    {
        
        [MyColumnName("cInvCode")]
        public string Material { get; set; }
        [MyColumnName("iQuantity")]
        public decimal Quantity { get; set; }
        [MyColumnName("iFlag")]
        public int Flag { get; set; } = 0;
        [MyColumnName("bLPUseFree")]
        public int LPUseFree { get; set; } = 0;
        [MyColumnName("bCosting")]
        public int Costing { get; set; } = 1;
        [MyColumnName("bVMIUsed")]
        public int bVMIUsed { get; set; } = 0;
        [MyColumnName("iExpiratDateCalcu")]
        public int ExpiratDateCalcu { get; private set; } = 0;
        [MyColumnName("iRowNo")]
        public int RowNo { get; set; }
        [MyColumnName("iOrderType")]
        public int OrderType { get; private set; } = 0;
        [MyColumnName("iSoType")]
        public int SoType { get; private set; } = 0;

        
    }

}
